import request from '@/utils/request'


export function listRecord(query) {
  return request({
    url: '/prod-api/subscribe/record/list',
    method: 'get',
    params: query
  })
}

export function getBuyRecord(uid) {
  return request({
    url: '/prod-api/customerService/buyRecord/getBuyRecord/'+uid,
    method: 'get'
  })
}


export function cardWithdrawal(data) {
  return request({
    url: '/prod-api/customerService/buyRecord/cardWithdrawal',
    method: 'post',
    data: data
  })
}

export function getRecordsList(query) {
  return request({
    url: '/prod-api/subscribe/record/getRecordsList',
    method: 'get',
    params: query
  })
}



export function getDetail(storeUid) {
  return request({
    url: '/prod-api/subscribe/record/getDetail/' + storeUid,
    method: 'get'
  })
}

export function listBuyRecord(query) {
  return request({
    url: '/prod-api/customerService/buyRecord/listBuyRecord',
    method: 'get',
    params: query
  })
}


export function editTechnician(data) {
  return request({
    url: '/prod-api/subscribe/record/editTechnician',
    method: 'post',
    data: data
  })
}

export function listComment(query) {
  return request({
    url: '/prod-api/subscribe/record/listComment',
    method: 'get',
    params: query
  })
}


export function editShow(data) {
  return request({
    url: '/prod-api/subscribe/record/editShow',
    method: 'post',
    data: data
  })
}

export function deleteRecord(uid) { //核销
  return request({
    url: `/prod-api/customerService/buyRecord/deleteBuyRecord/${uid}`,
    method: 'get'
  })
}